# -*- coding: utf-8 -*-#

# -------------------------------------------------------------------------------
# Name:         init_51job_page_list_link
# Description:  初始化列表页所有url
# Author:       zhuchunxu
# Date:         2020/11/3
# -------------------------------------------------------------------------------

import redis

from spider_source.utils.redis_utils import RedisUtils


def init_page_list_link():

    utils = RedisUtils()
    # 构造连接

    for i in range(1,500):
        url ="http://job.rc114.com/JobSearchCate.aspx?rc_sys=rc114&Page="+str(i)
        print("插入：", url)
        utils.conn.lpush("scrcJob:page_list_link", url)


if __name__ == "__main__":
    print("开始初始化。。。")
    init_page_list_link()
    print("执行完毕")
